import 'package:flutter/material.dart';
import 'package:flutter/services.dart';
import 'package:get/get.dart';
import 'package:getx_study/config/RouteConfig.dart';
import 'package:getx_study/http/http_utils.dart';

void main() {
  HttpUtils.init(baseUrl: "https://movie.douban.com");
  runApp(MyApp());
}

class MyApp extends StatelessWidget {
  // This widget is the root of your application.
  @override
  Widget build(BuildContext context) {
    SystemChrome.setPreferredOrientations([
      DeviceOrientation.portraitUp, //只能纵向
      DeviceOrientation.portraitDown,//只能纵向
    ]);
    return GetMaterialApp(
      debugShowCheckedModeBanner: false,
      initialRoute: RouteConfig.getVideoList,
      getPages: RouteConfig.getPages,
      title: 'Flutter Demo',
      theme: ThemeData(
        primarySwatch: Colors.blue,
        visualDensity: VisualDensity.adaptivePlatformDensity,
      ),
      // home: MyHomePage(title: 'Flutter Demo Home Page'),
    );
  }
}

